<template>
  <el-table
    :data="NoticeNotReadList"
    height="250"
    border
    v-loading="loading"
    style="width: 100%">
    <el-table-column
      prop="username"
      label="账号"
    >
    </el-table-column>
    <el-table-column
      prop="name"
      label="姓名">
    </el-table-column>
  </el-table>
</template>

<script>
  import {getNoticeNotReadList} from "../../api/notice";

  export default {
    name: "",
    props:{
      noticeId:''
    },
    data(){
      return{
        loading:false,
        NoticeNotReadList:[],
        listQuery:{
          page:1,
          size:5,
          noticeId:this.noticeId
        }
      }
    },
    methods:{
      getNoticeNotRead() {
        this.loading = true
        console.log("noticeid:"+this.noticeId)
        console.log(this.listQuery)
        getNoticeNotReadList(this.listQuery).then(res=>{
            this.NoticeNotReadList=res.data.pageList
          this.loading = false
        }).catch(err=>{
          this.loading = true
        })
      }
    },
    activated() {
      this.getNoticeNotRead()
    }
  }
</script>

<style scoped>

</style>
